<template>
  <div class="infoRoot">
    <img class="discover" :src="`${singerInfo.cover}?param=300y300`" alt="">
    <div class="right">
      <h3 class="name txtover">{{singerInfo.name}}</h3>
      <div class="btns">
        <div class="btnItem">
          <i class="iconfont icon-xihuan"> </i><span>{{isSub? '已收藏':"收藏"}}</span>
        </div>
        <div class="btnItem">
          <i class="iconfont icon-link"> </i><span>个人主页</span>
        </div>
      </div>
      <div class="otherInfo">
        <span class="micnum">单曲数：{{singerInfo.musicSize}}</span>
        <span class="micnum">专辑数：{{singerInfo.albumSize}}</span>
        <span class="micnum">MV数：{{singerInfo.mvSize}}</span>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  name: 'singerInfo',
  props: {
    singerInfo: {
      type: Object,
      default() {
        return {}
      }
    },
    isSub: {
      type: Boolean,
      default: false
    }
  },
  setup() {
    return {}
  }
}
</script>

<style scoped>
.infoRoot {
  display: flex;
  padding: 25px 10px;
  font-size: 12px;
}
.discover {
  margin-right: 15px;
  width: 150px;
  height: 150px;
  border-radius: 15px;
}
.right {
  flex: 1;
}
.btns,
.btnItem {
  display: flex;
  align-items: center;
}
.name {
  margin-bottom: 20px;
  font-size: 20px;
  font-weight: 600;
  color: #333;
  width: 90%;
}
.btnItem {
  margin-right: 10px;
  font-size: 12px;
  padding: 8px 16px;
  border: 1px solid #ddd;
  border-radius: 20px;
}
.otherInfo {
  margin: 15px 0;
  display: flex;
}
.micnum {
  margin-right: 10px;
}
</style>